<template>
	<view v-if="copyrightList">
	
		<vcustomer v-if='copyrightList.link_info'  :linkdata="copyrightList.link_info">
			<view class="copyright">
				<view class="copyright_content">
					<view class="img_box"><vimage v-if="copyrightList && copyrightList.logo" :src="copyrightList.logo"></vimage></view>
					<view class="content_title" v-if="copyrightList && copyrightList.name">{{ copyrightList.name }}</view>
					<view v-if="copyrightList && copyrightList.mobile">{{ copyrightList.mobile }}</view>
				</view>
			</view>
		</vcustomer>
		<view class="copyright" v-else>
			<view class="copyright_content">
				<view class="img_box"><vimage v-if="copyrightList && copyrightList.logo" :src="copyrightList.logo"></vimage></view>
				<view class="content_title" v-if="copyrightList && copyrightList.name">{{ copyrightList.name }}</view>
				<view v-if="copyrightList && copyrightList.mobile">{{ copyrightList.mobile }}</view>
			</view>
		</view>
	</view>
</template>

<script>
import http from '@/common/http.js';
export default {
	data() {
		return {
			copyrightList: {
				link_info:{}
			}
		};
	},
	mounted() {
		var _this = this;
		_this.getCopyright();
	},
	methods: {
		getCopyright() {
			http('/copyright', 'GET').then(res => {
				let copyrightList = res.data.msg || {};
				if (copyrightList.link_info) {
					copyrightList.link_info = JSON.parse(copyrightList.link_info);
				}

				this.copyrightList = copyrightList;
			});
		}
	}
};
</script>

<style lang="scss" scoped>
.copyright {
	width: 100%;
	box-sizing: border-box;
	font-size: 30rpx;
	text-align: center;
	padding-top: 20rpx;
	.copyright_content {
		font-size: 24rpx;
		.img_box {
			width: 180rpx;
			height: 60rpx;
			margin: auto;
		}
		.content_title {
			display: block;
			text-align: center;
			margin-bottom: 10rpx;
		}
	}
}

.difc {
	display: flex;
	align-items: center;
}
</style>
